PRINT N'Configuring queues';
GO

ALTER QUEUE WorkItems WITH 
		STATUS = ON,
		ACTIVATION	
		(
			STATUS = ON,
			PROCEDURE_NAME = WorkItemsReader,
			MAX_QUEUE_READERS = 1,
			EXECUTE AS OWNER
		);
GO

ALTER QUEUE [Control] WITH 
		STATUS = ON,
		ACTIVATION	
		(
			STATUS = ON,
			PROCEDURE_NAME = ControlQueueReader,
			MAX_QUEUE_READERS = 1,
			EXECUTE AS OWNER
		);
GO